package a.oschina.observedemo.demo4;

/**
 * &lt;功能详细描述&gt;
 *
 * @author Administrator
 * @version [版本号, 2018/10/23]
 * @see [相关类/方法]
 * @since [产品/模块版本]
 */
public class Test4 {
    public static void main(String[] args) {
        GrilObserver grilObserver = new GrilObserver();


        NbaMatcher nbaMatcher = new NbaMatcher("屌丝1号", grilObserver);
        NbaMatcher nbaMatcher2 = new NbaMatcher("屌丝二号", grilObserver);


        grilObserver.attach(nbaMatcher);
        grilObserver.attach(nbaMatcher2);

        grilObserver.setAction("班主任来了");

        grilObserver.notifyObserver();
    }
}
